
package com.karthik.client;

import com.karthik.DateConversionService;
import org.apache.cxf.jaxws.JaxWsProxyFactoryBean;


public class DateConversionServiceClient {

    private static final String ADDRESS="http://localhost:8080/convertdate/services/DateConversionWS";
    public static void main(String[] args) {
        JaxWsProxyFactoryBean fb=new JaxWsProxyFactoryBean();
        fb.setAddress(ADDRESS);
        fb.setServiceClass(DateConversionService.class);
        DateConversionService service=(DateConversionService) fb.create();
        System.out.println("The date converted is :"+service.convertDate(System.currentTimeMillis()));

    }
}
